package com.hongpu.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;

import com.hongpu.domain.HpProjectWorkPayListReceivePayment;
import com.hongpu.service.HpProjectWorkPayListReceivePaymentService;
import com.hongpu.mapper.HpProjectWorkPayListReceivePaymentMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
* @author Michael zhang
* @description 针对表【hp_project_work_pay_list_receive_payment(收款发票信息)】的数据库操作Service实现
* @createDate 2025-05-21 15:07:33
*/
@Service
public class HpProjectWorkPayListReceivePaymentServiceImpl extends ServiceImpl<HpProjectWorkPayListReceivePaymentMapper, HpProjectWorkPayListReceivePayment>
    implements HpProjectWorkPayListReceivePaymentService{

    @Autowired
    HpProjectWorkPayListReceivePaymentMapper baseMapper;

    /**
     * 修改为不需要开票
     *
     * @param payListId
     */
    @Override
    public boolean invoiceNot(Long payListId) {
        return baseMapper.invoiceNot(payListId) > 0 ? true:false;
    }
    /**
     * 修改为需要开票
     * @param hpProjectWorkPayListReceivePayment
     * @return
     */
    @Override
    public boolean invoice(HpProjectWorkPayListReceivePayment hpProjectWorkPayListReceivePayment) {
        return baseMapper.invoice(hpProjectWorkPayListReceivePayment) > 0 ? true:false;
    }

    @Override
    public List<HpProjectWorkPayListReceivePayment> getListByPayListId(Long payListId) {
        return baseMapper.getListByPayListId(payListId);
    }
}




